package cn.edu.hnu.gpg.dto;

import cn.edu.hnu.gpg.entity.Student;
import cn.edu.hnu.gpg.entity.Teacher;
import cn.edu.hnu.gpg.entity.User;
import cn.edu.hnu.gpg.entity.enums.UserType;

import java.sql.Date;

public class Account {

    private UserType userType;

    private User user;

    private Student student;

    private Teacher teacher;

    public Account() {}

    public Account(Student student) {
        this.userType = UserType.S;
        this.student = student;
    }

    public Account(Teacher teacher) {
        this.userType = UserType.T;
        this.teacher = teacher;
    }

    public void setUserType(UserType userType) {
        this.userType = userType;
    }

    public UserType getUserType() {
        return userType;
    }

    public void setUser(User user) {
        this.user = user;
    }

    public User getUser() {
        return user;
    }

    public void setStudent(Student student) {
        this.student = student;
    }

    public Student getStudent() {
        return student;
    }

    public void setTeacher(Teacher teacher) {
        this.teacher = teacher;
    }

    public Teacher getTeacher() {
        return teacher;
    }
}
